<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        body {
            margin: 0;
            padding: 20px;
            box-sizing: border-box;
        }

        .img-display {
            display: flex;
            flex-direction: row;
            justify-content: center;
            align-items: center;
            flex-wrap: nowrap;
            margin: 0 auto;
            background-color: #ccc;
            width: 75%;
            border-radius: 20px;
        }

        .img-display .image-item {
            position: relative;
            padding: 10px;

        }

        .img-display .image-item img {
            width: 200px;
            height: 150px;

            border-radius: 10px;
            box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);

        }

        .img-display .image-item .image-details {
            position: absolute;
            top: 10px;
            left: 10px;
            width: 200px;
            height: 150px;
            background-color: rgba(0, 0, 0, 0.5);
            display: flex;
            justify-content: center;
            align-items: center;
            flex-direction: column;
            opacity: 0;
            box-sizing: border-box;
            border-radius: 10px;
            box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);

        }

        .img-display .image-item:hover .image-details {
            opacity: 1;
            transition: 0.2s ease-in-out;

        }

        .img-display .image-item:hover {
            transform: scale(1.1);
        }


        .image-details h3,
        p {
            margin: 0;
            padding: 0;
            color: #fff;
        }
    </style>
</head>

<body>
    <div class="img-display">
        <div class="image-item">
            <img src="https://picsum.photos/id/238/800/600" alt="图片">
            <div class="image-details">
                <h3>图片1标题</h3>
                <p>图片描述</p>
            </div>
        </div>
        <div class="image-item">
            <img src="https://picsum.photos/id/247/800/600" alt="图片">
            <div class="image-details">
                <h3>图片2标题</h3>
                <p>图片2描述</p>
            </div>
        </div>
</body>

</html>